<?xml version="1.0" encoding="UTF-8" ?>
<html xmlns="http://www.w3.org/1999/xhtml" xsl:version="1.0"
    xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
    xmlns:sparql="http://www.w3.org/2005/sparql-results#"
    xmlns:rdfa="http://www.w3.org/ns/rdfa#"
    xmlns:xsd="http://www.w3.org/2001/XMLSchema#"
    xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
<head>
    <title>RDF Profile</title>
    <link rel="help" href="../../callimachus-for-web-developers" target="_blank" title="Help" />
</head>
<body>
    <h1>RDF Profile</h1>
    <div id="sidebar">
        <aside>
            <p>Namespace profiles are used to refer to resources using CURIES</p>
        </aside>
        <aside>
            <h3>Use of this Profile</h3>
            <ul>
                <li>Downloading RDF graphs</li>
                <li>Evaluating SPARQL queries</li>
                <li>Compiling internal SPARQL queries</li>
            </ul>
        </aside>
        <aside>
            <p>Removing items listed here can break the system</p>
        </aside>
    </div>
    <form role="form" method="POST" action="" autocomplete="off">
        <table class="graph">
            <thead>
                <tr><th>Prefix</th><th>URI</th></tr>
            </thead>
            <tbody class="sorted">
                <xsl:for-each select="rdf:RDF/rdf:Description">
                    <tr resource="{@rdf:about}">
                        <td property="rdfa:prefix" class="asc">
                            <xsl:value-of select="rdfa:prefix" />
                        </td>
                        <td property="rdfa:uri" content="{rdfa:uri/text()}">
                            <input type="text" class="form-control" name="{rdfa:prefix}" value="{rdfa:uri/text()}" />
                            <a href="javascript:void(0)" title="Remove entry" class="glyphicon glyphicon-remove"
                                 onclick="$(this).parents('tr:first').remove();return false" />
                        </td>				
                    </tr>
                </xsl:for-each>
            </tbody>
            <tbody>
                <tr>
                    <td>
                        <input type="text" class="form-control" size="8" onchange="$('#new-uri').attr('name', value)" />
                    </td>
                    <td>
                        <input type="text" class="form-control" id="new-uri" />
                        <a title="Remove entry" href="javascript:void(0)" class="glyphicon glyphicon-remove"
                             onclick="$(this).parents('tr:first').remove()" />
                    </td>
                </tr>
            </tbody>
        </table>
        <div class="hidden-logout">
            <button type="submit" class="btn btn-primary">Save</button>
            <button type="button" onclick="history.back()" class="btn btn-default">Cancel</button>
        </div>
    </form>
</body>
</html>
